﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Audio;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.GamerServices;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input;
using Microsoft.Xna.Framework.Media;
using Microsoft.Xna.Framework.Net;
using Microsoft.Xna.Framework.Storage;

namespace Ssb.Logic
{
    public class Bubble
        : GameComponent
    {
        public Vector2 Coords { get; set; }
        public int Radius { get; protected set; }

        public Bubble(Vector2 location, int radius, Game game)
            : base(game)
        {
            Coords = location;
            Radius = radius;
        }

        public bool isPointInside(Vector2 point)
        {
            Rectangle BBox = new Rectangle((int)(this.Coords.X - (this.Radius / 2)), (int)(this.Coords.Y - (this.Radius / 2)), this.Radius, this.Radius);
            return Logic.Physics.isPointInsideRectanle(point, BBox);
        }
    }
}
